package com.pactera.jep.service.sys.client;

import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.Map;

//@FeignClient(name = "ijep-service-schedule")
public interface JobEntityClient {

    @PostMapping("/jobEntity/updateCronExpression")
    Map<String, Object> updateCronExpression(@RequestParam("code") String code, @RequestParam("cronExpression") String cronExpression);

    @PostMapping("/jobEntity/getCronExpression")
    String getCronExpression(@RequestParam("code") String code);

    @RequestMapping("/jobEntity/start/{code}")
    Map<String, Object> start(@PathVariable("code") String code);

    @RequestMapping("/jobEntity/stop/{code}")
    Map<String, Object> stop(@PathVariable("code") String code);


}
